Infinity Dashboard Custom Module Tutorial



Main Documentation

Creating Your First Module: Hello World

NOTE — You can download the final resources from this tutorial by clicking here.

Starting a new module project is as simple as:

Step 1 – Create the module directory

TIP — To open the contents of this directory in Finder, Right Click the file, then select the Show Package Contents option.

Step 2 – Create the required files

package.json

{
  "name": "Hello World",
  "description": "A simple introduction to custom modules.",
  "author": "Your Name Here",
  "category": "utilities",
  "bundleID": "com.uniquebundle.helloworld",
  "version": "1.0.0", 
}

main.js

Step 3 – Writing Code

const fiplab = require('fiplab');

This is the first line of your file, and will allow you access to the fiplab module.

let returnString = 'Hello World';

The second line of your file defines a simple string that will be returned in Infinity Dashboard.

fiplab.exit(returnString, true);

This is the last line of your module and tells Infinity Dashboard that the module is done executing and tells it 2 key things:

Step 4 – Installing the module

Step 5 – Activating your custom module

In the Infinity Dashboard preferences

Success! — You’ve just made and installed your own custom module in Infinity Dashboard.

I see a red triangle when I run my module

This means your module encountered an error when it was trying to run or the success argument in the fiplab.exit method was set to false. You can debug your module and see the error by doing the following: